<?php
/* ---SESSAO DA RESENHA--- */
@session_start();
unset($_SESSION["resenha"]);
/* --------------------- */

include "../../jerimum/classes/bd.php";
include "../../jerimum/classes/anuncios.php";
$_anu		= new anuncios();

$dados	= $_anu->pega($_GET["anuncio"]);
$foto	= $_anu->pegaimagem($dados['id']);

?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>ESCREVER RESENHA >> <?=htmlentities($dados["titulo"])?> >> <?=htmlentities($dados["subtitulo"])?> </title>
<link href="../../css/estrutura.css" rel="stylesheet" type="text/css" />
<script type="text/javascript">

// JavaScript Document
function d(a){return document.getElementById(a);}
function idv(a){return document.getElementById(a).value;}

function abreNumCampo(campo){
	d(campo).style.display="";
	}
function FechaNumCampo(campo){
	d(campo).style.display="none";
	}

function blocTexto(valor,idtexto,idcampo,quantidade)
{
    quant = quantidade;
    total = valor.length;
    if(total <= quant)
    {
        resto = quant - total;
        document.getElementById(idtexto).innerHTML = resto;
    }
    else
    {
        document.getElementById(idcampo).value = valor.substr(0,quant);
    }
}
 


</script>

</head>

<body style="background-color:#FAFAFA">

<form action="cadastra.php" method="post">
<input type="hidden" name="idproduto" value="<?=$dados['id']?>" />
<div style="width:525px; margin:0px auto; background:#FAFAFA; padding:5px">
<div id="boxheader">
  <h2>VOC&Ecirc; SABE MAIS SOBRE ESTE ITEM?<span style=" font-size:12px; font-weight:normal"><br />
    Ganhe <strong>Estrelas</strong> de publicidade <strong>Solmais</strong> pela colabora&ccedil;&atilde;o de conte&uacute;do!</span></h2>
</div>
<div id="review_body">
  <p>
    <label for="fullname">FABRICANTE | MARCA | SELO</label><br />
    <input name="fabricacao" id="fabricacao" value="" size="40" maxlength="150"  onkeyup="javascript:blocTexto(this.value,'num_fabricacao','fabricacao',150);" onfocus="abreNumCampo('fabricacao_nu')" onblur="FechaNumCampo('fabricacao_nu')" />
  <span id="fabricacao_nu" style="display:none">&gt;&gt;    <span id="num_fabricacao">150</span>   caractere(s).</span></p>
  <p>
    <label for="fullname">ANO DE FABRICA&Ccedil;&Atilde;O</label><br />
    <input name="ano" type="text" id="ano" size="10" onkeyup="javascript:blocTexto(this.value,'num_fabricacao2','ano',8);" onfocus="abreNumCampo('fabricacao_nu2')" onblur="FechaNumCampo('fabricacao_nu2')" />
  <span id="fabricacao_nu2" style="display:none">&gt;&gt;    <span id="num_fabricacao2">8</span>   caractere(s).</span></p>
  <p>
    <label for="fullname">COR</label><br />
    <input name="cor" type="text" id="cor" size="30" onkeyup="javascript:blocTexto(this.value,'num_fabricacao3','cor',30);" onfocus="abreNumCampo('fabricacao_nu3')" onblur="FechaNumCampo('fabricacao_nu3')" />
    <span id="fabricacao_nu3" style="display:none">&gt;&gt;    <span id="num_fabricacao3">30</span>   caractere(s).</span><br />
    <br />
    <label for="fullname">PESO | MEDIDA</label><br />
    <input name="peso" type="text" id="peso" size="30"  onkeyup="javascript:blocTexto(this.value,'num_fabricacao4','peso',20);" onfocus="abreNumCampo('fabricacao_nu4')" onblur="FechaNumCampo('fabricacao_nu4')" />
    <span id="fabricacao_nu4" style="display:none">&gt;&gt;    <span id="num_fabricacao4">20</span>   caractere(s).</span><br />
    <br />
    <label for="fullname">GARANTIA</label>
    <br />
    <input name="garantia" type="text" id="garantia" size="30" onkeyup="javascript:blocTexto(this.value,'num_fabricacao5','garantia',30);" onfocus="abreNumCampo('fabricacao_nu5')" onblur="FechaNumCampo('fabricacao_nu5')" />
    <span id="fabricacao_nu5" style="display:none">&gt;&gt;    <span id="num_fabricacao5">30</span>   caractere(s).</span><br />
    <br />
    <label for="fullname">S&Eacute;RIE | MODELO | ESPECIFICA&Ccedil;&Otilde;ES</label><br />
    <input name="serie" type="text" id="serie" size="40" onkeyup="javascript:blocTexto(this.value,'num_fabricacao6','serie',50);" onfocus="abreNumCampo('fabricacao_nu6')" onblur="FechaNumCampo('fabricacao_nu6')" />
 <span id="fabricacao_nu6" style="display:none">&gt;&gt;    <span id="num_fabricacao6">50</span>   caractere(s).</span></p>
  <p>
    <label for="fullname">OBSERVA&Ccedil;&Otilde;ES:</label>
<span id="fabricacao_nu7" style="display:none">&gt;&gt;    <span id="num_fabricacao7">255</span>   caractere(s).</span><br />
    <textarea cols="60" rows="10" name="observacoes" wrap="soft" id="observacoes" onkeyup="javascript:blocTexto(this.value,'num_fabricacao7','observacoes',30);" onfocus="abreNumCampo('fabricacao_nu7')" onblur="FechaNumCampo('fabricacao_nu7')"></textarea>
    <br />
  </p>
  <p>
    <label for="email"></label>
  </p>
  </div>


<input name="button" type="reset" class="gh-btn" id="button2" value="Limpar" style="background-color:#F00; color:#FFFFFF; cursor:pointer" />
<input name="button2" type="submit" class="gh-btn" id="button3" value="Confirmar" style="background-color:#0A0; color:#FFFFFF; cursor:pointer;" />
 &gt;&gt; pr&oacute;ximo passo</div>
</form>
</body>
</html>
